package com.zzyl.nursing.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.zzyl.common.core.page.TableDataInfo;
import com.zzyl.nursing.domain.Reservation;
import com.zzyl.nursing.dto.ReservationDto;
import com.zzyl.nursing.vo.TimeCountVo;

import java.util.List;

public interface IMemberReservationService extends IService<Reservation> {
    int getCancelledReservationCount(Long userId);

    /**
     * 查询每个时间段剩余预约次数
     * @return
     */
    List<TimeCountVo> countReservationsForTime(Long time);

    /**
     * 新增预约信息
     */
    void addReservations(ReservationDto reservationDto);

    /**
     * 分页查询预约信息
     */
    List<Reservation> pageQuery(Integer status);

    /**
     * 取消预约
     */
    void cancelReservation(Long id);
}
